package com.gbk.clickhouseservicestruct.model;

import com.alibaba.fastjson.annotation.JSONField;
import com.fasterxml.jackson.annotation.JsonFormat;
import com.myweb.ck.mapping.ChTable;
import lombok.AllArgsConstructor;
import lombok.Builder;
import lombok.Data;
import lombok.NoArgsConstructor;
import org.springframework.format.annotation.DateTimeFormat;

import javax.persistence.Temporal;
import javax.persistence.TemporalType;
import java.util.Date;

/**
 * @Project: data-service
 * @Package: com.les.its.ds.model
 * @Author： mujian
 * @Create： 2023/9/18 14:04
 * @Description： TODO
 * @History: modify
 */
@ChTable(name = "tig.T_TIG_CROSS_EVENT_PRE")
@Data
@Builder
@NoArgsConstructor
@AllArgsConstructor
public class TIG_CROSS_EVENT_PRE {

    /**
     * 路口ID
     */
    private String cross_id;

    /**
     *车道
     */
    private Integer lane_no;

    /**
     *事件类型
     */
    private Integer event_type;

    /**
     *持续时间(分钟)
     */
    private Integer duration;

    /**
     * 影响范围（米）
     */
    private Integer affection_range;

    @Temporal(TemporalType.TIMESTAMP)
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm:ss", timezone = "GMT+8")
    @DateTimeFormat(pattern = "yyyy-MM-dd HH:mm:ss")
    @JSONField(format = "yyyy-MM-dd HH:mm:ss")
    private Date pre_time;
}
